import http from "@/http";
//新增数据类型
export type CateGory = {
    cagegoryId: string;
    categoryName: string;
    orderNum: string;
}
//列表数据类型
export type CateListParm = {
    currentPage: number;
    pageSize: number;
    categoryName: string;
}
//新增
export const addApi = (parm: CateGory) => {
    return http.post("/api/noticeCategory", parm)
}
//编辑
export const editApi = (parm: CateGory) => {
    return http.put("/api/noticeCategory", parm)
}
//删除
export const deleteApi = (cagegoryId: string) => {
    return http.delete(`/api/noticeCategory/${cagegoryId}`)
}
//列表
export const getListApi = (parm: CateListParm) => {
    return http.get("/api/noticeCategory/list", parm)
}
//公告下拉
export const getCateListApi = () => {
    return http.get("/api/noticeCategory/select")
}